<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>GUnixCredentialsMessage: GIO Reference Manual</title>
<meta name="generator" content="DocBook XSL Stylesheets Vsnapshot">
<link rel="home" href="index.html" title="GIO Reference Manual">
<link rel="up" href="networking.html" title="Low-level network support">
<link rel="prev" href="GCredentials.html" title="GCredentials">
<link rel="next" href="GProxy.html" title="GProxy">
<meta name="generator" content="GTK-Doc V1.26.1 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="5"><tr valign="middle">
<td width="100%" align="left" class="shortcuts">
<a href="#" class="shortcut">Top</a><span id="nav_description">  <span class="dim">|</span> 
                  <a href="#GUnixCredentialsMessage.description" class="shortcut">Description</a></span><span id="nav_hierarchy">  <span class="dim">|</span> 
                  <a href="#GUnixCredentialsMessage.object-hierarchy" class="shortcut">Object Hierarchy</a></span><span id="nav_properties">  <span class="dim">|</span> 
                  <a href="#GUnixCredentialsMessage.properties" class="shortcut">Properties</a></span>
</td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="16" height="16" border="0" alt="Home"></a></td>
<td><a accesskey="u" href="networking.html"><img src="up.png" width="16" height="16" border="0" alt="Up"></a></td>
<td><a accesskey="p" href="GCredentials.html"><img src="left.png" width="16" height="16" border="0" alt="Prev"></a></td>
<td><a accesskey="n" href="GProxy.html"><img src="right.png" width="16" height="16" border="0" alt="Next"></a></td>
</tr></table>
<div class="refentry">
<a name="GUnixCredentialsMessage"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="GUnixCredentialsMessage.top_of_page"></a>GUnixCredentialsMessage</span></h2>
<p>GUnixCredentialsMessage — A GSocketControlMessage containing credentials</p>
</td>
<td class="gallery_image" valign="top" align="right"></td>
</tr></table></div>
<div class="refsect1">
<a name="GUnixCredentialsMessage.functions"></a><h2>Functions</h2>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="functions_return">
<col class="functions_name">
</colgroup>
<tbody>
<tr>
<td class="function_type">
<a class="link" href="GSocketControlMessage.html" title="GSocketControlMessage"><span class="returnvalue">GSocketControlMessage</span></a> *
</td>
<td class="function_name">
<a class="link" href="GUnixCredentialsMessage.html#g-unix-credentials-message-new" title="g_unix_credentials_message_new ()">g_unix_credentials_message_new</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="GSocketControlMessage.html" title="GSocketControlMessage"><span class="returnvalue">GSocketControlMessage</span></a> *
</td>
<td class="function_name">
<a class="link" href="GUnixCredentialsMessage.html#g-unix-credentials-message-new-with-credentials" title="g_unix_credentials_message_new_with_credentials ()">g_unix_credentials_message_new_with_credentials</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="GCredentials.html" title="GCredentials"><span class="returnvalue">GCredentials</span></a> *
</td>
<td class="function_name">
<a class="link" href="GUnixCredentialsMessage.html#g-unix-credentials-message-get-credentials" title="g_unix_credentials_message_get_credentials ()">g_unix_credentials_message_get_credentials</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a href="../glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
</td>
<td class="function_name">
<a class="link" href="GUnixCredentialsMessage.html#g-unix-credentials-message-is-supported" title="g_unix_credentials_message_is_supported ()">g_unix_credentials_message_is_supported</a> <span class="c_punctuation">()</span>
</td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="GUnixCredentialsMessage.properties"></a><h2>Properties</h2>
<div class="informaltable"><table class="informaltable" border="0">
<colgroup>
<col width="150px" class="properties_type">
<col width="300px" class="properties_name">
<col width="200px" class="properties_flags">
</colgroup>
<tbody><tr>
<td class="property_type">
<a class="link" href="GCredentials.html" title="GCredentials"><span class="type">GCredentials</span></a> *</td>
<td class="property_name"><a class="link" href="GUnixCredentialsMessage.html#GUnixCredentialsMessage--credentials" title="The “credentials” property">credentials</a></td>
<td class="property_flags">Read / Write / Construct Only</td>
</tr></tbody>
</table></div>
</div>
<div class="refsect1">
<a name="GUnixCredentialsMessage.other"></a><h2>Types and Values</h2>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="name">
<col class="description">
</colgroup>
<tbody>
<tr>
<td class="datatype_keyword"> </td>
<td class="function_name"><a class="link" href="GUnixCredentialsMessage.html#GUnixCredentialsMessage-struct" title="GUnixCredentialsMessage">GUnixCredentialsMessage</a></td>
</tr>
<tr>
<td class="datatype_keyword">struct</td>
<td class="function_name"><a class="link" href="GUnixCredentialsMessage.html#GUnixCredentialsMessageClass" title="struct GUnixCredentialsMessageClass">GUnixCredentialsMessageClass</a></td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="GUnixCredentialsMessage.object-hierarchy"></a><h2>Object Hierarchy</h2>
<pre class="screen">    <a href="../gobject-The-Base-Object-Type.html#GObject-struct">GObject</a>
    <span class="lineart">╰──</span> <a class="link" href="GSocketControlMessage.html" title="GSocketControlMessage">GSocketControlMessage</a>
        <span class="lineart">╰──</span> GUnixCredentialsMessage
</pre>
</div>
<div class="refsect1">
<a name="GUnixCredentialsMessage.includes"></a><h2>Includes</h2>
<pre class="synopsis">#include &lt;gio/gunixcredentialsmessage.h&gt;
</pre>
</div>
<div class="refsect1">
<a name="GUnixCredentialsMessage.description"></a><h2>Description</h2>
<p>This <a class="link" href="GSocketControlMessage.html" title="GSocketControlMessage"><span class="type">GSocketControlMessage</span></a> contains a <a class="link" href="GCredentials.html" title="GCredentials"><span class="type">GCredentials</span></a> instance.  It
may be sent using <a class="link" href="GSocket.html#g-socket-send-message" title="g_socket_send_message ()"><code class="function">g_socket_send_message()</code></a> and received using
<a class="link" href="GSocket.html#g-socket-receive-message" title="g_socket_receive_message ()"><code class="function">g_socket_receive_message()</code></a> over UNIX sockets (ie: sockets in the
<a class="link" href="GSocketAddress.html#G-SOCKET-FAMILY-UNIX:CAPS"><code class="literal">G_SOCKET_FAMILY_UNIX</code></a> family).</p>
<p>For an easier way to send and receive credentials over
stream-oriented UNIX sockets, see
<a class="link" href="GUnixConnection.html#g-unix-connection-send-credentials" title="g_unix_connection_send_credentials ()"><code class="function">g_unix_connection_send_credentials()</code></a> and
<a class="link" href="GUnixConnection.html#g-unix-connection-receive-credentials" title="g_unix_connection_receive_credentials ()"><code class="function">g_unix_connection_receive_credentials()</code></a>. To receive credentials of
a foreign process connected to a socket, use
<a class="link" href="GSocket.html#g-socket-get-credentials" title="g_socket_get_credentials ()"><code class="function">g_socket_get_credentials()</code></a>.</p>
</div>
<div class="refsect1">
<a name="GUnixCredentialsMessage.functions_details"></a><h2>Functions</h2>
<div class="refsect2">
<a name="g-unix-credentials-message-new"></a><h3>g_unix_credentials_message_new ()</h3>
<pre class="programlisting"><a class="link" href="GSocketControlMessage.html" title="GSocketControlMessage"><span class="returnvalue">GSocketControlMessage</span></a> *
g_unix_credentials_message_new (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
<p>Creates a new <a class="link" href="GUnixCredentialsMessage.html" title="GUnixCredentialsMessage"><span class="type">GUnixCredentialsMessage</span></a> with credentials matching the current processes.</p>
<div class="refsect3">
<a name="g-unix-credentials-message-new.returns"></a><h4>Returns</h4>
<p> a new <a class="link" href="GUnixCredentialsMessage.html" title="GUnixCredentialsMessage"><span class="type">GUnixCredentialsMessage</span></a></p>
</div>
<p class="since">Since: <a class="link" href="api-index-2-26.html#api-index-2.26">2.26</a></p>
</div>
<hr>
<div class="refsect2">
<a name="g-unix-credentials-message-new-with-credentials"></a><h3>g_unix_credentials_message_new_with_credentials ()</h3>
<pre class="programlisting"><a class="link" href="GSocketControlMessage.html" title="GSocketControlMessage"><span class="returnvalue">GSocketControlMessage</span></a> *
g_unix_credentials_message_new_with_credentials
                               (<em class="parameter"><code><a class="link" href="GCredentials.html" title="GCredentials"><span class="type">GCredentials</span></a> *credentials</code></em>);</pre>
<p>Creates a new <a class="link" href="GUnixCredentialsMessage.html" title="GUnixCredentialsMessage"><span class="type">GUnixCredentialsMessage</span></a> holding <em class="parameter"><code>credentials</code></em>
.</p>
<div class="refsect3">
<a name="g-unix-credentials-message-new-with-credentials.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>credentials</p></td>
<td class="parameter_description"><p>A <a class="link" href="GCredentials.html" title="GCredentials"><span class="type">GCredentials</span></a> object.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-unix-credentials-message-new-with-credentials.returns"></a><h4>Returns</h4>
<p> a new <a class="link" href="GUnixCredentialsMessage.html" title="GUnixCredentialsMessage"><span class="type">GUnixCredentialsMessage</span></a></p>
</div>
<p class="since">Since: <a class="link" href="api-index-2-26.html#api-index-2.26">2.26</a></p>
</div>
<hr>
<div class="refsect2">
<a name="g-unix-credentials-message-get-credentials"></a><h3>g_unix_credentials_message_get_credentials ()</h3>
<pre class="programlisting"><a class="link" href="GCredentials.html" title="GCredentials"><span class="returnvalue">GCredentials</span></a> *
g_unix_credentials_message_get_credentials
                               (<em class="parameter"><code><a class="link" href="GUnixCredentialsMessage.html" title="GUnixCredentialsMessage"><span class="type">GUnixCredentialsMessage</span></a> *message</code></em>);</pre>
<p>Gets the credentials stored in <em class="parameter"><code>message</code></em>
.</p>
<div class="refsect3">
<a name="g-unix-credentials-message-get-credentials.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>message</p></td>
<td class="parameter_description"><p>A <a class="link" href="GUnixCredentialsMessage.html" title="GUnixCredentialsMessage"><span class="type">GUnixCredentialsMessage</span></a>.</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-unix-credentials-message-get-credentials.returns"></a><h4>Returns</h4>
<p>A <a class="link" href="GCredentials.html" title="GCredentials"><span class="type">GCredentials</span></a> instance. Do not free, it is owned by <em class="parameter"><code>message</code></em>
. </p>
<p><span class="annotation">[<acronym title="Don't free data after the code is done."><span class="acronym">transfer none</span></acronym>]</span></p>
</div>
<p class="since">Since: <a class="link" href="api-index-2-26.html#api-index-2.26">2.26</a></p>
</div>
<hr>
<div class="refsect2">
<a name="g-unix-credentials-message-is-supported"></a><h3>g_unix_credentials_message_is_supported ()</h3>
<pre class="programlisting"><a href="../glib-Basic-Types.html#gboolean"><span class="returnvalue">gboolean</span></a>
g_unix_credentials_message_is_supported
                               (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
<p>Checks if passing <a class="link" href="GCredentials.html" title="GCredentials"><span class="type">GCredentials</span></a> on a <a class="link" href="GSocket.html" title="GSocket"><span class="type">GSocket</span></a> is supported on this platform.</p>
<div class="refsect3">
<a name="g-unix-credentials-message-is-supported.returns"></a><h4>Returns</h4>
<p> <a href="../glib-Standard-Macros.html#TRUE:CAPS"><code class="literal">TRUE</code></a> if supported, <a href="../glib-Standard-Macros.html#FALSE:CAPS"><code class="literal">FALSE</code></a> otherwise</p>
</div>
<p class="since">Since: <a class="link" href="api-index-2-26.html#api-index-2.26">2.26</a></p>
</div>
</div>
<div class="refsect1">
<a name="GUnixCredentialsMessage.other_details"></a><h2>Types and Values</h2>
<div class="refsect2">
<a name="GUnixCredentialsMessage-struct"></a><h3>GUnixCredentialsMessage</h3>
<pre class="programlisting">typedef struct _GUnixCredentialsMessage GUnixCredentialsMessage;</pre>
<p>The <a class="link" href="GUnixCredentialsMessage.html" title="GUnixCredentialsMessage"><span class="type">GUnixCredentialsMessage</span></a> structure contains only private data
and should only be accessed using the provided API.</p>
<p class="since">Since: <a class="link" href="api-index-2-26.html#api-index-2.26">2.26</a></p>
</div>
<hr>
<div class="refsect2">
<a name="GUnixCredentialsMessageClass"></a><h3>struct GUnixCredentialsMessageClass</h3>
<pre class="programlisting">struct GUnixCredentialsMessageClass {
  GSocketControlMessageClass parent_class;
};
</pre>
<p>Class structure for <a class="link" href="GUnixCredentialsMessage.html" title="GUnixCredentialsMessage"><span class="type">GUnixCredentialsMessage</span></a>.</p>
<p class="since">Since: <a class="link" href="api-index-2-26.html#api-index-2.26">2.26</a></p>
</div>
</div>
<div class="refsect1">
<a name="GUnixCredentialsMessage.property-details"></a><h2>Property Details</h2>
<div class="refsect2">
<a name="GUnixCredentialsMessage--credentials"></a><h3>The <code class="literal">“credentials”</code> property</h3>
<pre class="programlisting">  “credentials”              <a class="link" href="GCredentials.html" title="GCredentials"><span class="type">GCredentials</span></a> *</pre>
<p>The credentials stored in the message.</p>
<p>Flags: Read / Write / Construct Only</p>
<p class="since">Since: <a class="link" href="api-index-2-26.html#api-index-2.26">2.26</a></p>
</div>
</div>
<div class="refsect1">
<a name="GUnixCredentialsMessage.see-also"></a><h2>See Also</h2>
<p><a class="link" href="GUnixConnection.html" title="GUnixConnection"><span class="type">GUnixConnection</span></a>, <a class="link" href="GSocketControlMessage.html" title="GSocketControlMessage"><span class="type">GSocketControlMessage</span></a></p>
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.26.1</div>
</body>
</html>